import {
    getHotDjerListAPI,
    getHoursDjerListAPI,
    getNewDjerListAPI
} from '../../api/djer';

// 获取热门主播
export const getHotDjerListAction = () => {
    return async (dispatch) => {
        let res = await getHotDjerListAPI();
        const data = res.data.data;
        dispatch({
            type: '',
            data
        });
        return data;
    }
}

// 获取24小时主播榜
export const getHoursDjerListAction = () => {
    return async (dispatch) => {
        let res = getHoursDjerListAPI();
        const data = res.data;
        dispatch({
            type: '',
            data
        });
    }
}

// 获取新主播
export const getNewDjerListAction = () => {
    return async (dispatch) => {
        let res = getNewDjerListAPI();
        const data = res.data;
        dispatch({
            type: '',
            data
        });
    }
}